<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core"%>
<%@ taglib uri="http://www.springframework.org/tags/form" prefix="form"%>

<link rel="stylesheet" href='<c:url value="/resources/css/redmond/jquery-ui-1.8.16.custom.css"/>' />
<script type="text/javascript" src='<c:url value="/resources/js/jquery-1.6.2.min.js"/>'></script>
<script type="text/javascript" src='<c:url value="/resources/js/jquery-ui-1.8.16.custom.min.js"/>'></script>
<script type="text/javascript" src='<c:url value="/resources/js/baseUtil.js"/>'></script>
<script type="text/javascript" src='<c:url value="/resources/js/system/userManagement.js"/>'></script>

<fieldset>
<legend>员工管理</legend>
<input id="addOperatorButton" type="button" value="添加">
<div id="userTable">
</div>
<div id="addOperatorFormDiv" title="添加员工">
	<form id="addUserForm">
		<table>
			<tr>
				<td>登录名:</td>
				<td><input type="text" name="loginName"/></td>
			</tr>
			<tr>
				<td>姓名:</td>
				<td><input type="text" name="name"/></td>
			</tr>
			<tr>
				<td>密码:</td>
				<td><input type="password" name="password"/></td>
			</tr>
			<tr>
				<td>确认密码:</td>
				<td><input type="password" name="re_password" id="repassword"></td>
			</tr>
			<tr>
				<td>权限:</td>
				<td>
					<select name="permission">
						<option value="N">普通员工</option>
						<option value="A">会计</option>
						<option value="L">领导</option>
					</select>
				</td>
			</tr>
			<tr>
				<td>&nbsp;</td>
				<td align="right"><input id="saveButton" type="button" value="保存"></td>
			</tr>
		</table>
	</form>
</div>
<div id="updateUserFormDiv" title="编辑员工">
	<form id="updateUserForm">
		<table>
			<tr>
				<td>登录名:</td>
				<td>
					<input type="hidden" name="userId" id="userId"/>
					<input type="text" name="loginName" id="loginName"/>
				</td>
			</tr>
			<tr>
				<td>姓名:</td>
				<td><input type="text" name="newName" id="newName"/></td>
			</tr>
			<tr>
				<td>密码:</td>
				<td><input type="password" name="newPassword" id="newPassword"/></td>
			</tr>
			<tr>
				<td>确认密码:</td>
				<td><input type="password" name="re_password" id="new_repassword"></td>
			</tr>
			<tr>
				<td>权限:</td>
				<td>
					<select name="newPermission" id="newPermission">
						<option value="N">普通员工</option>
						<option value="A">会计</option>
						<option value="L">领导</option>
					</select>
				</td>
			</tr>
			<tr>
				<td>&nbsp;</td>
				<td align="right"><input id="updateButton" type="button" value="保存"></td>
			</tr>
		</table>
	</form>
</div>
</fieldset>